package dancetwotiktokenumsmymongo

const (
	DanceRoomModelCpTypeCp       = 0 //cp
	DanceRoomModelCpTypeCancelCp = 1 //解散cp

	DanceRoomModelCpDoTypeAuto  = 0 //0:系统自动;1:管理后台;
	DanceRoomModelCpDoTypeAdmin = 1 //0:系统自动;1:管理后台;

	DanceRoomModelUserRelation       = 1 //组成
	DanceRoomModelCancelUserRelation = 2 //解散
)

type DanceRoomModelLogEnums struct {
}

var DanceRoomModelLogEnumsObject DanceRoomModelLogEnums

func (e DanceRoomModelLogEnums) LogType() []int {
	return []int{
		DanceRoomModelCpTypeCp,
		DanceRoomModelCpTypeCancelCp,
	}
}

func (e DanceRoomModelLogEnums) LogTypeMap() map[int]int {
	m := make(map[int]int)
	for _, s := range e.LogType() {
		m[s] = s
	}
	return m
}

func (e DanceRoomModelLogEnums) LogTypeString(tag int) string {
	switch tag {
	case DanceRoomModelCpTypeCp:
		return "组成CP"
	case DanceRoomModelCpTypeCancelCp:
		return "解散CP"
	default:
		return "未知"
	}
}

func (e DanceRoomModelLogEnums) DoType() []int {
	return []int{
		DanceRoomModelCpDoTypeAuto,
		DanceRoomModelCpDoTypeAdmin,
	}
}

func (e DanceRoomModelMarryLogEnums) DoTypeMap() map[int]int {
	m := make(map[int]int)
	for _, s := range e.DoType() {
		m[s] = s
	}
	return m
}

func (e DanceRoomModelMarryLogEnums) DoTypeString(tag int) string {
	switch tag {
	case DanceRoomModelCpDoTypeAuto:
		return "自动"
	case DanceRoomModelCpDoTypeAdmin:
		return "后台操作"
	default:
		return "未知"
	}
}

func (e DanceRoomModelMarryLogEnums) RelationType() []int {
	return []int{
		DanceRoomModelUserRelation,
		DanceRoomModelCancelUserRelation,
	}
}

func (e DanceRoomModelMarryLogEnums) TripTaskNameMap() map[int]string {
	m := make(map[int]string)
	for _, s := range e.RelationType() {
		m[s] = e.RelationTypeString(s)
	}
	return m
}

func (e DanceRoomModelMarryLogEnums) RelationTypeString(tag int) string {
	switch tag {
	case DanceRoomModelUserRelation:
		return "组成"
	case DanceRoomModelCancelUserRelation:
		return "解散"
	default:
		return "未知"
	}
}
